import Vue from 'vue';
import Router from 'vue-router';

Vue.use(Router);

export default new Router({
  routes: [{
      path: '/',
      redirect: '/login'
    },
    {
      path: '/',
      component: () => import( /* webpackChunkName: "home" */ '../components/common/Home.vue'),
      meta: {
        title: '自述文件'
      },
      children: [{
          path: '/dashboard',
          component: () => import( /* webpackChunkName: "dashboard" */ '../components/page/Dashboard.vue'),
          meta: {
            title: '系统首页'
          }
        }, {
          path: '/dataStatistics',
          component: () => import( /* webpackChunkName: "dashboard" */ '../components/page/dataStatistics/dataStatistics.vue'),
          meta: {
            title: '数据统计(地域)'
          }
        }, {
          path: '/provinceSaleData',
          component: () => import( /* webpackChunkName: "dashboard" */ '../components/page/dataStatistics/provinceSaleData.vue'),
          meta: {
            title: '省销售数据统计(地域)'
          }
        }, {
          path: '/citySaleData',
          component: () => import( /* webpackChunkName: "dashboard" */ '../components/page/dataStatistics/citySaleData.vue'),
          meta: {
            title: '市销售数据统计(地域)'
          }
        }, {
          path: '/areaSaleData',
          component: () => import( /* webpackChunkName: "dashboard" */ '../components/page/dataStatistics/areaSaleData.vue'),
          meta: {
            title: '区销售数据统计(地域)'
          }
        }, {
          path: '/provinceActivityData',
          component: () => import( /* webpackChunkName: "dashboard" */ '../components/page/dataStatistics/provinceActivityData.vue'),
          meta: {
            title: '省活跃度统计(地域)'
          }
        }, {
          path: '/cityActivityData',
          component: () => import( /* webpackChunkName: "dashboard" */ '../components/page/dataStatistics/cityActivityData.vue'),
          meta: {
            title: '市活跃度统计(地域)'
          }
        }, {
          path: '/areaActivityData',
          component: () => import( /* webpackChunkName: "dashboard" */ '../components/page/dataStatistics/areaActivityData.vue'),
          meta: {
            title: '区活跃度统计(地域)'
          }
        }, {
          path: '/bigUserInfo',
          component: () => import( /* webpackChunkName: "dashboard" */ '../components/page/bigUser/bigUserInfo.vue'),
          meta: {
            title: '大客户专员信息'
          }
        }, {
          path: '/set',
          component: () => import( /* webpackChunkName: "dashboard" */ '../components/page/bigUser/set.vue'),
          meta: {
            title: '设置'
          }
        }, {
          path: '/moneyList',
          component: () => import( /* webpackChunkName: "dashboard" */ '../components/page/moneyManage/moneyList.vue'),
          meta: {
            title: '钱包列表'
          }
        }, {
          path: '/orderList',
          component: () => import( /* webpackChunkName: "dashboard" */ '../components/page/moneyManage/orderList.vue'),
          meta: {
            title: '订单列表'
          }
        }, {
          path: '/checkOrderList',
          component: () => import( /* webpackChunkName: "dashboard" */ '../components/page/moneyManage/checkOrderList.vue'),
          meta: {
            title: '审核订单列表'
          }
        },{
          path: '/withdrawList',
          component: () => import( /* webpackChunkName: "dashboard" */ '../components/page/moneyManage/withdrawList.vue'),
          meta: {
            title: '提现列表'
          }
        }
      ]
    },
    {
      path: '/login',
      component: () => import( /* webpackChunkName: "login" */ '../components/page/Login.vue'),
      meta: {
        title: '登录'
      }
    },
    {
      path: '*',
      redirect: '/404'
    }
  ]
});